home *** CD-ROM | disk | FTP | other *** search
- #!/bin/csh -f
-
- if ($#argv < 2) then
- xconfirm -t "Error converting cosmo button file." \
- -t "Converter requires 2 arguments." >& /dev/null
- exit 1
- endif
-
- # Handy variables
- set SOURCE = $argv[1]
- set TARGET = $argv[2]
- set APPDIR = /usr/lib/CosmoCreate/
- set RENDER = $APPDIR/apps/render
- set TOGIF = $APPDIR/apps/sgitogif
-
- # Make sure we can clobber target
- touch $TARGET >&/dev/null
- if ($status) then
- xconfirm -t "Couldn't render to target file:" \
- -t $TARGET \
- -t "Check permissions" \
- -b "OK"
- endif
-
- # This tmpname could clobber another once in
- # a billion years, on leap day :)
- set TMPNAME = $TARGET.`date +%j%H%M%S`
-
- # Render image
-
- $RENDER -f $SOURCE -o $TMPNAME -b -D 4 -A >& /dev/null
- $TOGIF $TMPNAME $TARGET >& /dev/null
-
- rm $TMPNAME
-
-
-